package com.ahui.ydd.service;

import com.ahui.ydd.Vo.HotVo;
import com.ahui.ydd.Vo.MyArticleVo;
import com.ahui.ydd.Vo.NewVo;
import com.ahui.ydd.Vo.YddArticleVo;
import com.ahui.ydd.entity.YddArticle;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

public interface YddArticleService extends IService<YddArticle> {
    /**
     * 热门置顶文章数据(首页)
     *
     * @param pageInfo
     * @return
     */
    NewVo selectByPage(Page<YddArticle> pageInfo);

    Page<YddArticleVo> pageByCondition(Page<YddArticle> pageInfo, LambdaQueryWrapper<YddArticle> queryWrapper);

    /**
     * 最新文章
     *
     * @return
     */
    HotVo YddArticleCatelist();

    /**
     * 我的文章
     * @param pageInfo
     * @param queryWrapper
     * @return
     */
    MyArticleVo selectByMyArticlePage(Page<YddArticle> pageInfo, LambdaQueryWrapper<YddArticle> queryWrapper);

}